Levator Ani
The pubococcygeal part of levator ani attaches to the back of the pubic body and passes posteriorly, in an almost horizontal orientation.  Posterior to the rectum a tendinous plate formed from pubococcygeal fibers attaches to the anterior surface of the coccyx.

The iliococcygeal part arises from obturator fascia and the ischial spine.  The fibers meet with the anococcygeal ligament to form a raphe.  This attaches to the sides of the lower two coccygeal segments.

Sphincter Ani Externus 
The deep part of sphincter ani externus blends with the puborectalis muscle with some posterior fibers attaching to the anococcygeal raphe.

The superficial part of sphincter ani externus attaches anteriorly to the perineal body and posteriorly to the posterior surface of the last coccygeal segment via the median anococcygeal raphe.

The subcutaneous part of sphincter ani externus attaches anteriorly to the perineal body and posteriorly some fibers attach to the anococcygeal raphe.